package com.goddess.yeecolor.activity;

import android.os.Bundle;
import android.webkit.WebSettings;
import android.webkit.WebView;
import android.webkit.WebViewClient;

import com.goddess.yeecolor.R;
import com.goddess.yeecolor.base.BaseActivity;

/**
 * 作者: CaoJunping
 * 时间: 2017/2/10
 * 作用: ******
 * 备注: ******
 */
public class TestActivity extends BaseActivity {
   private WebView view;

    @Override
    public void onCreate(Bundle savedInstanceState) {
        setTheme(R.style.AppTheme);
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_test);
        //syncCookie(this,MyUrl.JSCOOKIE);
        //setmOkttp(MyUrl.JSCOOKIE);
        view= (WebView) findViewById(R.id.webview);
     //   syncCookie(MyUrl.JSCOOKIE);
        WebSettings settings = view.getSettings();
        String ua = settings.getUserAgentString();
        settings.setUserAgentString(ua + "; android_app/1.0.0");
       // view.loadUrl(MyUrl.JSCOOKIE);
        view.setWebViewClient(new WebViewClient() {
            @Override
            public boolean shouldOverrideUrlLoading(WebView view, String url) {
                view.loadUrl(url);
                return true;
            }
        });
    }

    @Override
    public void initOnClck() {

    }

    @Override
    public void initFindView() {

    }

    @Override
    public void initData() {

    }
}
